#define _CRT_SECURE_NO_WARNINGS 
#include <stdio.h>
int arr[40000] = { 0 };
int main()
{
	scanf("%d", &arr[0]);
	int sum = 0;
	for (int i = 1; ; i++)
	{
		scanf("%d", &arr[i]);
		sum += arr[i];
		if (sum == arr[0] * arr[0])
			break;
	}
	int t = 0;
	for (int i = 1; ; i++)
	{
		if (i % 2 != 0)
		{
			while (arr[i])
			{
				printf("0");
				arr[i]--;
				t++;
				if (t % arr[0] == 0)
					printf("\n");
			}
		}
		else
		{
			while (arr[i])
			{
				printf("1");
				arr[i]--;
				t++;
				if (t % arr[0] == 0)
					printf("\n");
			}
		}
		if (t == arr[0] * arr[0])
			break;
	}
	return 0;
}